<template>
	<view>

	</view>
</template>

<script>
	export default {
		data() {
			return {

			}
		},
		onLoad(options) {
			if (this.isMobile()) {
				uni.redirectTo({
					url: `/pages/respond/pend/pendMobile?id=${options.id}&type=${options.type}`
				})
			} else {
				uni.redirectTo({
					url: `/pages/respond/pend/pendDetail?id=${options.id}&type=${options.type}&staging=no`
				})
			}
		},
		methods: {
			// 是否手机端
			isMobile() {
				const mobileFlag = {}
				mobileFlag.value = navigator.userAgent.match(
					/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i
				)
				if (mobileFlag.value) {
					return true;
				} else {
					return false;
				}
			},
		}
	}
</script>

<style>

</style>